import Vue from 'vue'
import Router from 'vue-router'
import Home from '@/components/home'
import Introduce from '@/components/introduce'
import Product from '@/components/product'
import Cooperation from '@/components/cooperation'
import Journalism from '@/components/journalism'
import Index from '@/components/index'

Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/',
      name: 'home',
      component: Home,
      redirect: "/index",
      children: [
        {
          path: 'index',
          name: 'index',
          component: Index
        },
        {
          path: 'introduce',
          name: 'introduce',
          component: Introduce
        },
        {
          path: 'product',
          name: 'product',
          component: Product
        },
        {
          path: 'cooperation',
          name: 'cooperation',
          component: Cooperation
        },
        {
          path: 'journalism',
          name: 'journalism',
          component: Journalism
        }
      ]
    },

  ]
})
